#ifndef USART_H__
#define USART_H__

#include <string.h>
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "driver/uart.h"
#include "driver/uart_select.h"
#include "driver/gpio.h"

#define UART_TYPE_NUM UART_NUM_0
#define UART_TX_PIN GPIO_NUM_43
#define UART_RX_PIN GPIO_NUM_44

#define UART_TRNAS_NUM UART_NUM_1
#define UART_TRANS_TX_PIN GPIO_NUM_17
#define UART_TRANS_RX_PIN GPIO_NUM_18

#define RX_BUF_SIZE 1024 /* 环形缓冲区大小 */

#define ACK_TX_SIZE (10)

void usart_init(uint32_t baud);
void uart1_init(uint32_t bound);

#endif